package com.whfc.safety.enums;

/**
 * @author : qzexing
 * @version : 1.0
 * @date : 2020-07-29 16:06
 */
public enum UrgencyLevel {

    GENERAL(1, "一般"),

    URGENCY(2, "紧急");

    private Integer value;

    private String desc;

    public Integer getValue() {
        return value;
    }

    public String getDesc() {
        return desc;
    }

    UrgencyLevel(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public static UrgencyLevel parseValue(Integer value) {
        switch (value) {
            case 1:
                return GENERAL;
            case 2:
                return URGENCY;
            default:
                return null;
        }
    }
}
